package com.jctrip.hotel.management.config;

import com.jctrip.hotel.management.interceptor.JwtTokenInterceptor;
import org.springframework.stereotype.Component;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

@Component
public class ManageMentInterceptorConfig implements WebMvcConfigurer {
    @Override
    public void addInterceptors(InterceptorRegistry registry) {
//        registry.addInterceptor(new JwtTokenInterceptor())
//                .excludePathPatterns("/sys/user/login")
//                .excludePathPatterns("/management/route/listHotels")
//                .excludePathPatterns("/swagger-resources/**", "/webjars/**", "/v2/**", "/swagger-ui.html/**", "/swagger-ui.html", "/doc.html")
//                .addPathPatterns("/management/**")
//                .addPathPatterns("/sys/**");
    }
}
